package cn.edu.csust.coursecard.dao.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.Date;

/**
 *  帖子
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@Accessors(chain = true)
public class Post implements Serializable {
    
    //帖子id
    private Integer id;

    //主题id
    private Integer themeId;

    //发帖人
    private Integer userId;
    
    //内容
    private String content;
    
    //点赞数量
    private Integer likeNum;
    
    //评论数量
    private Integer commentNum;
    
    //是否匿名
    private Boolean isAnonymous;
    
    
    //创建时间
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date createTime;
    
    //修改时间
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date updateTime;
    
    //逻辑删除
    private Boolean isValid;
    
}
